#{extends 'master.html' /}
#{set title:'DigitalBand.ru - Контакты' /}
#{set isContactsActive:'active' /}
<div class="page-header">
    <div>
        <h3 class="categoryTitle">Контакты</h3>
        <div class="clear"></div>
    </div>

</div>
<div class="page-block">
    <!--TODO: content must go from DB-->
    <description>
        <p>
        &{'Shop.contacts.content'}</p>
    </description>

#{form @ask()}
    #{if flash.error}
        <p class="error">
        &{flash.error}
        </p>
    #{/if}
    #{if flash.success}
        <p class="success">
        &{flash.success}
        </p>
    #{/if}
    <div class="form">
        <fieldset>
            <div>
                <label for="username">&{'Shop.contacts.username'}</label>
                <input type="text" name="pq.username" id="username" value="${flash.get('pq.username')}"/>
            </div>
            <div>
                <label for="email">&{'Shop.contacts.email'}</label>
                <input type="text" name="pq.email" id="email" value="${flash.get('pq.email')}"/>
            </div>
            <div>
                <label for="productTitle">Название товара</label>
                <input id="productTitle" type="text" name="pq.productTitle" value="${flash.get('pq.productTitle')}" />
                <input type="hidden" name="pq.productId" />
            </div>
            <div>
                <label for="message">&{'Shop.contacts.body'}</label>
                <textarea name="pq.body" id="message" cols="5" rows="5">${flash.get('pq.body')}</textarea>
            </div>
            <div>
                <label for="captcha">Код проверки</label>
                <div id="captcha" style="display: inline-block;">
                    <script type="text/javascript">
                        var RecaptchaOptions = {
                            theme : 'white',
                            custom_translations : {
                                instructions_visual : "Введите код:",
                                instructions_audio : "Послушать:",
                                play_again : "Играть снова",
                                cant_hear_this : "Не слышу",
                                visual_challenge : "Код",
                                audio_challenge : "Послушать",
                                refresh_btn : "Получить новый код",
                                help_btn : "Помощь",
                                incorrect_try_again : "Неверный код. Попробуйте еще раз"
                            }
                        };
                    </script>
                    <script type="text/javascript"
                            src="http://www.google.com/recaptcha/api/challenge?k=6LfuQdYSAAAAANoCLOZIRyPFnJ8quXNnCjTWb46c">
                    </script>
                    <noscript>
                        <iframe src="http://www.google.com/recaptcha/api/noscript?k=6LfuQdYSAAAAANoCLOZIRyPFnJ8quXNnCjTWb46c"
                                height="300" width="500" frameborder="0"></iframe><br>
                        <textarea name="recaptcha_challenge_field" rows="3" cols="40">
                        </textarea>
                        <input type="hidden" name="recaptcha_response_field"
                               value="manual_challenge">
                    </noscript>
                </div>
            </div>
        </fieldset>
    </div>
    <div class="bottom-button">
        <input type="submit" id="signin" value="&{'Shop.contacts.ask'}"/>
    </div>
#{/form}
</div>